﻿<?php
class test extends CI_Controller
{
	function  t($para = 'default para')
	{
		
		
		$this->load->database();
		$query = $this->db->query('select * from t1');
		foreach ($query->result() as $row)
		{
			echo $row->col1;
			echo $row->col2;
		}
		
		die('over');
		
			echo '参数是：'.$para;
			
			$this->load->library('encrypt');
			$msg = '123456abcdefghijklmn';
			
			echo '<br>';
			$msg1 = $this->encrypt->encode($msg);
			echo '加密：'. $msg1;
			
			echo '<br>';
			$msg2 = $this->encrypt->decode($msg1);
			echo '解密：'.$msg2;
	
		
	}
	
}